package com.hugh.commom;

import com.hugh.commom.serializer.impl.JSONSerializer;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
import lombok.ToString;

import java.io.Serializable;

/**
 * @Author: Hugh
 * @Date: 2020/6/13
 */
@Data
@NoArgsConstructor
@AllArgsConstructor
@Builder
public class RpcResponse extends JSONSerializer implements Serializable {


    /**
     * 返回值信息
     */
    private Object response;

    /**
     * 请求对象的ID
     */
    private Long requestId;


    /**
     * server端的ip和端口
     */
    private String ipPort;

    @Override
    public String toString() {
        return "RpcResponse{" +
                "response=" + response +
                ", requestId=" + requestId +
                ", ipPort='" + ipPort + '\'' +
                '}';
    }
}
